package BasicDataStructures;

public class TreeNode {
    public TreeNode left;
    public TreeNode right;
    public TreeNode parent;
    public int val;

    public TreeNode(int val) {
        this.val = val;
    }

    public TreeNode(TreeNode left, TreeNode right) {
        this.left = left;
        this.right = right;
    }

    public TreeNode() {
    }

    public TreeNode(TreeNode left, TreeNode right, TreeNode parent) {
        this.left = left;
        this.right = right;
        this.parent = parent;
    }

    public TreeNode(TreeNode left, TreeNode right, TreeNode parent, int val) {
        this.left = left;
        this.right = right;
        this.parent = parent;
        this.val = val;
    }
}
